home *** CD-ROM | disk | FTP | other *** search
/ Clickx 115 / Clickx 115.iso / software / tools / windows / tails-i386-0.16.iso / live / filesystem.squashfs / var / lib / dpkg / info / im-switch.postinst < prev    next >
Encoding:
Text File  |  2010-06-22  |  1.5 KB  |  63 lines

  1. #!/bin/sh
  2. set -e
  3.  
  4. ua_inst () {
  5.     update-alternatives \
  6.         --install /etc/X11/xinit/xinput.d/$1 xinput-$1 \
  7.         /etc/X11/xinit/xinput.d/$2 $3 ;
  8. }
  9.  
  10. # fix for 90im-switch -> 80im-switch transition. (After 1.13)
  11. # If old version exists, clean it up. 
  12.  
  13. if [ -f /etc/X11/Xsession.d/90im-switch ]; then
  14.     case `md5sum /etc/X11/Xsession.d/90im-switch|sed 's/ .*$//'` in
  15.     # md5sum for previous releases
  16.     0555954437ad61fe51850fae0a89378d |\
  17.         58e24e5a127a953e05a0bed82b943700 |\
  18.     cb724d4db7f531b50c218007a2b9d7f2 |\
  19.     fac350767f9316f0ceb65b7da9638f5f |\
  20.     9711c96cdaf57a74f36793c30e964537 |\
  21.     012637550e0bfbdf83f703474acccea2 |\
  22.     acb685ae9264be3fc1800f98a70b12bb )
  23.     rm -f /etc/X11/Xsession.d/90im-switch
  24.     ;;
  25.     * )
  26.     echo You have customized /etc/X11/Xsession.d/90im-switch file
  27.     echo with its md5sum = `md5sum /etc/X11/Xsession.d/90im-switch|sed 's/ .*$//'`.
  28.     echo Please remove it or move it up to 80im-switch.
  29.     ;;
  30.     esac
  31. fi
  32.  
  33.  
  34. case "$1" in
  35.     configure)
  36.         # Set up default
  37.         ua_inst all_ALL default  10
  38.         ua_inst all_ALL default-xim  0
  39.         ua_inst lo_TH lo-gtk  10
  40.         ua_inst all_ALL none  0
  41.         ua_inst th_TH th-xim  20
  42.         ua_inst th_TH th-gtk  10
  43.     ;;
  44.  
  45.     abort-upgrade|abort-remove|abort-deconfigure)
  46.  
  47.     ;;
  48.  
  49.     *)
  50.         echo "postinst called with unknown argument \`$1'" >&2
  51.         exit 1
  52.     ;;
  53. esac
  54.  
  55. # Automatically added by dh_installmenu
  56. if [ "$1" = "configure" ] && [ -x "`which update-menus 2>/dev/null`" ]; then
  57.     update-menus
  58. fi
  59. # End automatically added section
  60.  
  61.  
  62. exit 0
  63.